package com.sanji.sjmallmodule.account;

import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.widget.ImageView;
import android.widget.TextView;

import com.sanji.sjmallapp.BaseActivity;
import com.sanji.sjmallapp.R;
import com.sanji.sjmallmodule.account.ChangePayPwActivity;
import com.sanji.sjmallmodule.account.ForgetPwActivity;

import butterknife.BindView;
import butterknife.ButterKnife;

public class SetUserInfoActivity extends BaseActivity implements View.OnClickListener {

    @BindView(R.id.common_back_img)
    ImageView commonBackImg;
    @BindView(R.id.common_left_tv)
    TextView commonLeftTv;
    @BindView(R.id.set_change_pw)
    TextView setChangePw;
    @BindView(R.id.set_forget_pw)
    TextView setForgetPw;
    Intent intent = null;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_set);
        ButterKnife.bind(this);
        initView();
    }

    public void initView() {
        commonLeftTv.setText(getString(R.string.set_user_info));
        commonBackImg.setOnClickListener(this);
        setChangePw.setOnClickListener(this);
        setForgetPw.setOnClickListener(this);
    }

    @Override
    public void onClick(View view) {
        switch (view.getId()) {
            case R.id.common_back_img:
                finish();
                break;
            case R.id.set_change_pw:
                //修改支付密码
                intent = new Intent(this, ChangePayPwActivity.class);
                startActivity(intent);
                break;
            case R.id.set_forget_pw:
                //忘记支付密码
                intent = new Intent(this, ForgetPwActivity.class);
                startActivity(intent);
                break;
        }
    }
}
